Skip to content

Conversation

@yaauie
Copy link
Member

@yaauie yaauie commented Oct 3, 2025

Release notes

  • fixes an issue with Central Management where a spurious 404 when looking up pipeline definitions could cause the running pipelines to shut down.

What does this PR do?

When Central Management is looking up the instance's assigned pipelines, it now confirms a 404 is in fact an empty assignment, differentiating it from a 404 emitted for other reasons.

Why is it important/What is the impact to the user?

An ES node leaving the cluster can emit a 404, indicating that it cannot satisfy the request, which is different than an indication that the list of pipelines is empty.

This fix prevents such a 404 from shutting down the running pipelines.

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • [ ] I have made corresponding changes to the documentation
  • [ ] I have made corresponding change to the default configuration files (and/or docker env variables)
  • I have added tests that prove my fix is effective or that my feature works

How to test this PR locally

Related issues

@github-actions
Copy link
Contributor

github-actions bot commented Oct 3, 2025

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

@mergify
Copy link
Contributor

mergify bot commented Oct 3, 2025

This pull request does not have a backport label. Could you fix it @yaauie? 🙏
To fixup this pull request, you need to add the backport labels for the needed
branches, such as:

  • backport-8./d is the label to automatically backport to the 8./d branch. /d is the digit.
  • If no backport is necessary, please add the backport-skip label

CHANGED BEHAVIOR (system indices):

 - when communicating with Elasticsearch >= 7.10, a fetch-all-pipelines query
   that results in a 404 error is treated as a meaningful error since
   Elasticsearch does NOT emit 404 when no pipelines have been configured,
   preventing a misconfigured proxy from causing pipelines to be shut down
 - when communicating with Elasticsearch >= 8.3, a server-side query for
   pipelines that results in a 404 error response no longer results in the
   immediate shut-down of existing pipelines unless a second client-side
   filtering of all available pipelines indicates that none should be running.

MAINTAINED BEHAVIOUR (legacy hidden indices):

 - when commmunicating with Elasticsearch < 7.10, a pipeline-fetching query
   that results in a 404 error response is STILL treated as an empty result
   set, and will cause any running pipelines to be shut down.
@yaauie yaauie force-pushed the central-management-confirm-the-404 branch from af0a331 to 252d4e0 Compare November 11, 2025 00:26
@yaauie yaauie requested a review from kaisecheng November 11, 2025 16:09
Copy link
Contributor

@kaisecheng kaisecheng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Confirmed the API returns the corresponding codes as described.
I left a minor suggestion.

# search to rule out a proxy emitting a 404.
if es_supports_pipeline_wildcard_search?(es_version)
begin
logger.trace("querying for pipelines #{pipeline_ids.join(",")} using server-side wildcard search")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
logger.trace("querying for pipelines #{pipeline_ids.join(",")} using server-side wildcard search")
logger.trace? && logger.trace("querying for pipelines #{pipeline_ids.join(",")} using server-side wildcard search")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Unexpected pipeline shutdown with central-managed configurations

3 participants